<#assign base=request.contextPath>
<!DOCTYPE html> 
<html>
	<head>
		<title></title>
		<meta charset="utf-8">
		<#include "common/reference.ftl" />
		<#include "common/ligerui.ftl" />
		<script type="text/javascript">
		<!--
			var ligerTable = null;
			$(function(){
				$('.select-chosen').chosen();
				$('.date-picker').datepicker();
				ligerTable = $('#table').ligerGrid({
					width:'98%',
					enabledSort:false,
					pageSizeOptions:[5,10,20,50,100,200],
					height:'auto',
					alternatingRow:true,
					url:'${base}/${route}/getList',
					delayLoad:false,
					columns:[
						{display:'记录编号',name:'recordNo',id:'recordNo',align:'center',minWidth:150},
						{display:'openId',name:'userUniqueId',id:'userUniqueId',align:'center',minWidth:220},
						{
							display:'用户类型',
							name:'userType',
							id:'userType',
							align:'center',
							minWidth:150,
							render:function(row){
								var userType = row.userType;
								if(userType == 1){
									return '用户';
								}
								else if(userType == 2){
									return '司机';
								}
								else if(userType == 4){
									return '公司';
								}else if(userType == 8){
                                    return '分公司';
                                }
								return '-';
							}
						},
						{display:'流动产值',name:'flowAmount',id:'flowAmount',align:'center',minWidth:80},
						{
							display:'流动方向',
							name:'inOut',
							id:'inOut',
							align:'center',
							minWidth:150,
							render:function(row){
								var inOut = row.inOut;
								if(inOut == 1){
									return '流进';
								}
								else if(inOut == 2){
									return '流出';
								}
								return '-';
							}
						},
						{display:'流动去向',name:'flowTo',id:'flowTo',align:'center',minWidth:150},
						{
							display:'流动方式',
							name:'flowMode',
							id:'flowMode',
							align:'center',
							minWidth:150,
							render:function(row){
								var flowMode = row.flowMode;
								if(flowMode == 1){
									return '支付宝';
								}
								else if(flowMode == 2){
									return '微信';
								}
								else if(flowMode == 3){
								    /* ycs 180911
									return '余额';
									*/
                                    return '余额(已作废)';
								}
								return '-';
							}
						},
						{display:'关联单号',name:'linkNo',id:'linkNo',align:'center',minWidth:150},
						{display:'资金用途',name:'purpose',id:'purpose',align:'center',minWidth:150},
						{display:'备注',name:'remark',id:'remark',align:'center',minWidth:150}
					]
				});
				
				function reload(){
					if(ligerTable){
						var searchKey = $('#txtSearchKey').val();
						ligerTable.setParm('searchKey',searchKey);
						ligerTable.reload();
					}
				}
				$('#btnSearch').click(function(){
					reload();
				})
			});
		//-->
		</script>
	</head>
	<body class="$configs["skinName"]">
		<#include "common/breadcrumb.ftl">
		<div class="widget-box">
			<div class="widget-header widget-header-flat">
				<h5 class="lighter">
					<i class="fa fa-search"></i>
					${module}查询
				</h5>
			</div>
			<div class="widget-body">
				<div class="widget-main">
					<div class="space-4"></div>
					<div class="row">
						<div class="col-sm-6">
							<div class="input-group">
								<span class="input-group-addon">关键字</span>
								<input id="txtSearchKey" type="text" class="form-control search-query" placeholder="请输关键字搜索" />
								<span class="input-group-btn">
									<button id="btnSearch" type="button" class="btn btn-purple btn-sm">
										查询
										<i class="icon-search icon-on-right bigger-110"></i>
									</button>
								</span>
							</div>
						</div>
					</div>
				</div>
			</div>
		</div>
		<div class="widget-box">
			<div class="widget-header">
				<h5 class="lighter">
					<i class="icon-table"></i>
					${module}列表
				</h5>
			</div>
			<div class="widget-body">
				<div id="table"><div>
			</div>
		</div>
	</body>
</html>